﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Web;

namespace SMBCFamilyAssessment.Models
{
     [Table("Person")]
    public class Person
    {
        [ScaffoldColumn(false)]
        [Key]
        public int PersonId { get; set; }
        [Required]
        public int FamilyId { get; set; }  
        [StringLength(35)]
        [DataType(DataType.Text),Display(Name="First Name")]
        public string FirstName { get; set; }
        [StringLength(35)]
        [DataType(DataType.Text), Display(Name = "Last Name")]
        public string LastName { get; set; }
        [DataType(DataType.Date), Display(Name = "DOB (DD/MM/YYYY)")]
        public DateTime? DOB { get; set; }
        [StringLength(1000)]
        [DataType(DataType.MultilineText)]
        public string Notes { get; set; }
        [ScaffoldColumn(false)]
         public string CreatedBy { get; set; }
        [ScaffoldColumn(false)]
        public DateTime? CreatedDateTime { get; set; }
        [ScaffoldColumn(false)]
        public string UpdatedBy { get; set; }
        [ScaffoldColumn(false)]
        [DatabaseGenerated(DatabaseGeneratedOption.Computed)]
        public DateTime? UpdatedDateTime { get; set; }
        public DateTime? EndedDateTime { get; set; }
        [ScaffoldColumn(false)]
        public virtual Family Family { get; set; }
        public virtual List<Assessment> Assessments { get; set; }





    }
}